﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Diagnostics;

namespace Ashlen.Utility.Mail
{
    public sealed class Log
    {
        public static void LogEvent(EventLogEntryType type, string message) {
            try {
                EventLog.WriteEntry("News Feed Service", message, type);
            }
            catch (Exception ex) {
                try {
                    EventLog.WriteEntry("News Feed Service", ex.ToString(), EventLogEntryType.Error);
                    Console.WriteLine(ex.ToString());
                }
                catch { }
            }
        }
    }
}
